package org.example;

import javafx.application.Application;
import org.apache.catalina.core.ApplicationContext;
import org.example.spring.AService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

@SpringBootApplication
public class Main {


@Autowired
private static ApplicationContext applicationContext;
    public static void main(String[] args) {

        ConfigurableApplicationContext run = SpringApplication.run(Main.class, args);
        AService bean = run.getBean(AService.class);
        bean.test();


    }
}